/*
 * @Author: yangni 920556271@qq.com
 * @Date: 2024-01-03 11:47:25
 * @LastEditors: yangni 920556271@qq.com
 * @LastEditTime: 2024-04-09 14:25:46
 * @FilePath: /yt-devops/lib/pages/devices/device_tab/utils/device_util.dart
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:yt_devops/styles/styles.dart';

class DeviceUtil {
  static Widget blockContainer(Widget child, {EdgeInsets? padding}) {
    return Container(
      color: Colour.white,
      margin: EdgeInsets.only(top: 10.h),
      padding: padding ?? EdgeInsets.only(bottom: 0, left: 16.w, right: 16.w),
      child: child,
    );
  }

  static Widget headTitle(String title,
      {EdgeInsets? padding, double height = 53, Color color = Colors.white}) {
    return Container(
      alignment: Alignment.centerLeft,
      height: height,
      padding: padding,
      color: color,
      child: Text(
        title,
        style: TextStyles.f18.mediumStyle,
        maxLines: 2,
      ),
    );
  }
}
